package com.ruoyi.subject.domain;

import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.constraints.NotBlank;

/**
 * 题项对象 t_qb_subject_item
 *
 * @author lzhj
 * @date 2021-01-20
 */
@Api("题项对象")
public class QbSubjectItem extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * 主键
     */
    private Long id;

    /**
     * 题目id
     */
    @NotBlank(message = "题目id不能为空")
    @ApiModelProperty(value = "题目id")
    @Excel(name = "题目id")
    private Long subjectId;

    /**
     * 题项内容
     */
    @NotBlank(message = "题项内容不能为空")
    @ApiModelProperty(value = "题项内容，200字")
    @Excel(name = "题项内容")
    private String content;

    /**
     * 题项code
     */
    @NotBlank(message = "题项code不能为空")
    @ApiModelProperty(value = "题项code，字典表subject_code")
    @Excel(name = "题项code")
    private String code;

    /**
     * 是否正确答案
     */
    @NotBlank(message = "是否正确答案不能为空")
    @ApiModelProperty(value = "是否正确答案，字典表bus_sf")
    @Excel(name = "是否正确答案")
    private String correct;

    public void setId(Long id) {
        this.id = id;
    }

    public Long getId() {
        return id;
    }

    public void setSubjectId(Long subjectId) {
        this.subjectId = subjectId;
    }

    public Long getSubjectId() {
        return subjectId;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getContent() {
        return content;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getCode() {
        return code;
    }

    public void setCorrect(String correct) {
        this.correct = correct;
    }

    public String getCorrect() {
        return correct;
    }

//    @Override
//    public String toString() {
//        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
//                .append("id", getId())
//                .append("subjectId", getSubjectId())
//                .append("content", getContent())
//                .append("code", getCode())
//                .append("correct", getCorrect())
//                .append("createBy", getCreateBy())
//                .append("createTime", getCreateTime())
//                .append("updateBy", getUpdateBy())
//                .append("updateTime", getUpdateTime())
//                .append("remark", getRemark())
//                .toString();
//    }


    @Override
    public String toString() {
        return "QbSubjectItem{" +
                "id=" + id +
                ", subjectId=" + subjectId +
                ", content='" + content + '\'' +
                ", code='" + code + '\'' +
                ", correct='" + correct + '\'' +
                '}';
    }
}
